home *** CD-ROM | disk | FTP | other *** search
/ The Arcade BBS / arcadebbs.zip / arcadebbs / bbstools / WWIV Mods / WWIVMOD.ZIP / RIPMOD1.MOD < prev    next >
Encoding:
Text File  |  1993-10-16  |  14.8 KB  |  433 lines

  1. RIPMOD2a ("THE COMPLETE RIP PACKAGE") file1
  2. ``Midiman`` WWIVnet #330 AT 856
  3. 0Sunday, October 3, 1993  9:45 pm 3-=1[5JST1]3=-0
  4. 0R: net33: @9 (via @22) [07:51 10/08/93]
  5. 0R: net33: @22 (via @7) [07:42 10/08/93]
  6. 0R: net33: @7 (via @8) [07:16 10/08/93]
  7. 0R: net33: @8 (via @1) [07:23 10/08/93]
  8. 0R: net33: @15 [06:06 10/08/93]
  9. 0R: net33: @4062 (via @4064) [06:27 10/06/93]
  10. 0R: net33: @4064 (via @1040) [03:36 10/06/93]
  11. 0R: net33: @1040 (via @2050) [12:04 10/05/93]
  12. 0R: net34: @2050 [09:48 10/05/93]
  13. 0R: net34: @2050 (via @1040) [16:16 10/04/93]
  14. 0R: net33: @1040 (via @856) [16:12 10/04/93]
  15. 0R: net33: @856 [22:06 10/03/93]
  16. ┌────────────────────────────────────────────────────────────────────────────┐
  17. │ Mod Name:        RIPMOD2a               Mod Author:    MidiMan #1@850      │
  18. │ Difficulty:      Normal                 Date:          09-17-1993          │
  19. │ WWIV Version:    4.22                   Update         09-26-1993          │
  20. │ Description:     Adds RIPscrip to WWIV                                     │
  21. │                           FILE # 1                                         │
  22. └────────────────────────────────────────────────────────────────────────────┘
  23. =============================================================================
  24. [#1] [LOAD] BBSUTL.C  search and add the /* modded code */
  25. =============================================================================
  26. inside of char *mmkey(int dl)
  27.     
  28.     ch=upcase(ch);
  29.     if (!rip)           /* RIP MOD */
  30.     outchr(ch);
  31.     if (ch==13)
  32.  
  33. go down a little further, to "int set_language_1(int n)"
  34. (thanks Trail Rider)
  35.  
  36. Look for:
  37.  
  38. read_in_file("MENUSANS.MSG",menus1,sizeof(menus1)/sizeof(menus1[0]));
  39. read_in_file("MENUS40.MSG",menus2,sizeof(menus2)/sizeof(menus2[0]));
  40. read_in_file("MENUS.RIP",menus3,sizeof(menus3)/sizeof(menus3[0])); /* RipMod */
  41.  
  42.   return(0);
  43. }
  44.  
  45. Save BBSUTL.C
  46. =========================================================================
  47. [#2] [LOAD] VARS.H   search and add the /* modded code */
  48. =========================================================================
  49. Look for:
  50.  
  51. __EXTRN__ messagerec helps[50], menus[30],menus1[30],menus2[30];
  52.  
  53. And change it to....
  54.  
  55. __EXTRN__ messagerec helps[50], menus[30],menus1[30],menus2[30],menus3[30];
  56.  
  57. Also, under   __EXTRN__ int ...etc.. add rip, ripflg, and mm :
  58.  
  59.               num_sec, num_subs, num_sys_list, oklevel, okmacro, okskey,
  60.               ok_modem_stuff, oldx, oldy, ooneuser, outcom,
  61.               userfile, usernum, useron, use_workspace, using_modem,
  62.               wfc, x_only, rip,ripflg,mm; /* added rip,ripflg,mm */
  63.  
  64. Save VARS.H
  65. =============================================================================
  66. [#3] [LOAD] MSGBASE1.C  search and add the /* modded code */
  67. =============================================================================
  68. Search for void printmenu.
  69.  
  70. void printmenu(int i)
  71. {
  72.   char s[81],s1[81];
  73.   int next;
  74.  
  75.   next=0;
  76.   if (rip) {                                           /* Rip Mod */
  77.     sprintf(s1,"MENU%u.RIP", i);                       /* Rip Mod */
  78.     sprintf(s,"%s%s",languagedir,s1);                  /* Rip Mod */
  79.     ripflg=1;                                          /* Rip Mod */
  80.     if (exist(s)) {                                    /* Rip Mod */
  81.       printfile(s1);                                   /* Rip Mod */
  82.       return;                                          /* Rip Mod */
  83.     }                                                  /* Rip Mod */
  84.                                                        /* Rip Mod */
  85.     if (menus3[i].stored_as) {                         /* Rip Mod */
  86.       sprintf(s,"%sMENUS.RIP",languagedir);            /* Rip Mod */
  87.       ripflg=1;                                        /* Turn on Rip Flag */
  88.       read_message1(&menus3[i],0,0,&next,s);           /* Rip Mod */
  89.       ripflg=0;                                        /* Turn off Rip Flag */
  90.     }                                                  /* Rip Mod */
  91.       else {                                           /* Rip Mod */
  92.             if ((okansi()) && (menus1[i].stored_as)) { /* Rip Mod */
  93.               sprintf(s,"%sMENUSANS.MSG",languagedir); /* Rip Mod */
  94.               read_message1(&menus1[i],0,0,&next,s);   /* Rip Mod */
  95.             } else {                                   /* Rip Mod */
  96.                 sprintf(s,"%sMENUS.MSG",languagedir);  /* Rip Mod */
  97.                 if (menus[i].stored_as)                /* Rip Mod */
  98.                 read_message1(&menus[i],0,0,&next,s);  /* Rip Mod */
  99.               }                                        /* Rip Mod */
  100.       }                                                /* Rip Mod */
  101.   ripflg=0;                                            /* RIP Mod */
  102.   return;                                              /* Rip Mod */
  103.   }                                                    /* Rip Mod */
  104.  
  105.   if ((thisuser.sysstatus & (sysstatus_color | sysstatus_ansi))
  106.       == (sysstatus_color | sysstatus_ansi)) {
  107.     sprintf(s1,"MENU%u.ANS", i);
  108.     sprintf(s,"%s%s",languagedir,s1);
  109.     if (exist(s)) {
  110.       printfile(s1);
  111.       return;
  112.     }
  113.   }
  114.  
  115. Save  MSGBASE1.C 
  116. =============================================================================
  117. [#4] [LOAD] SHRINK.C   search and add the /* modded code */
  118. =============================================================================
  119.  
  120. add the following line in * int restore_data(char *s)
  121.   READ(sysop_alert);
  122.   READ(do_event);
  123.   READ(rip);              /* Rip Mod. */
  124.  
  125.   if (stat) {
  126.     READ(andwith);
  127.  
  128. We must also add this to the Write Statement. Search for...
  129. void save_state(char *s, int state,int ctc)
  130.  
  131. Add the folowing line.......
  132.  
  133.   WRITE(do_event);
  134.   WRITE(rip);               /* Mod Add */
  135.  
  136.   WRITE(andwith);
  137.   WRITE(usernum);
  138.  
  139. Save SHRINK.C                                                            
  140. =============================================================================
  141. [#5] [LOAD] BBS.C      search and add the /* modded code */
  142. =============================================================================
  143.  
  144. void mainmenu(void)
  145. {
  146.   char *s, s1[81],s2[81],ch;
  147.   int i;
  148.   long l;
  149.   double d;
  150.  
  151.   ...further down...replace this if statement for expert/novice menus
  152.      
  153.      if ((sysstatus_expert & thisuser.sysstatus)==0) {  /* RIP MOD */
  154.         if (!mm) {                                      /* RIP MOD */
  155.         printmenu(0);                                   /* RIP MOD */
  156.         ripcut();                                       /* RIP MOD */
  157.         lines_listed=0;                                 /* RIP MOD */
  158.         } else                                          /* RIP MOD */
  159.         mm=0;                                           /* RIP MOD */
  160.       }                                                 /* RIP MOD */
  161.  
  162.  further down.....
  163.  
  164.   nl();
  165.   tleft(1);
  166.   if (!rip)                              /* RIP MOD */
  167.   npr("T - %s\r\n",ctim(nsl()));
  168.   s1[0]=0;
  169.  
  170. Further down....
  171.       
  172.       case '>':
  173.       case '+':
  174.  if ((cursub<num_subs-1) && (usub[cursub+1].subnum>=0))
  175.    ++cursub;
  176.  else
  177.    cursub=0;
  178.  mm=1;                  /* RIP MOD */  
  179.  break;
  180.       case '<':
  181.       case '-':
  182.  if (cursub>0)
  183.    --cursub;
  184.  else {
  185.    while ((usub[cursub+1].subnum>=0) && (cursub<num_subs-1))
  186.      ++cursub;
  187.  }
  188.  mm=1;                  /* RIP MOD */  
  189. break;
  190.  
  191. further down look for and * replace * this whole case.     
  192.  
  193.      case 'I':
  194.  nl();
  195.  npr("%s   (%s)\r\n",wwiv_version, wwiv_date);
  196.  nl();
  197.  printfile("LOGON");
  198.  rippause();           /* RIP MOD */
  199.  printfile("SYSTEM");
  200.  rippause();           /* RIP MOD */
  201.  break;                
  202.  
  203. NOTE: after each case in mainmenu & dlmainmenu  add a RIPWINDOW() or RIPBIG() 
  204.  
  205. for example:
  206.       case 'A':
  207.  ripwindow();
  208.  helpl=19;
  209.  write_automessage();
  210.  break;
  211.  
  212. search for and * replace * whole case in void mainmenu(void)
  213.       
  214.       case 'O':
  215.  helpl=12;
  216.  ripoff(); 
  217.    if (!rip) {
  218.    nl();
  219.    nl();
  220.    prt(5,get_string(28));
  221.  if (yn()) {
  222.    outchr(12);
  223.    outstr(get_string(29));
  224.    pl(ctim(timer()-timeon));
  225.    printfile("LOGOFF");
  226.    hangup=1;
  227.  }
  228.  }
  229.   break;
  230.  
  231. *NOTE*  do the same for CASE 'O" in the dlmainmenu logoff command.      
  232.  
  233. Change the case '?': in the void mainmenu to this....
  234.  
  235.       case '?':                                        /* RIP MOD */
  236.   if ((sysstatus_expert & thisuser.sysstatus)==0)      /* RIP MOD */
  237.      nl();                                             /* RIP MOD */
  238.      else                                              /* RIP MOD */
  239.       printmenu(0);                                    /* RIP MOD */    
  240.   break;                                               /* RIP MOD */
  241.  
  242. In the void dlmainmenu(), alter/add the following 
  243.      
  244.      if ((sysstatus_expert & thisuser.sysstatus)==0) {  /* RIP MOD */
  245.         if (!mm) {                                      /* RIP MOD */
  246.         printmenu(3);                                   /* RIP MOD */
  247.         ripcut();                                       /* RIP MOD */
  248.         lines_listed=0;                                 /* RIP MOD */
  249.         } else                                          /* RIP MOD */
  250.         mm=0;                                           /* RIP MOD */
  251.       }                                                 /* RIP MOD */
  252.  
  253. further down....
  254.  
  255.       case '>':
  256.       case '+':
  257.  if ((curdir<num_dirs-1) && (udir[curdir+1].subnum>=0))
  258.    ++curdir;
  259.  else
  260.    curdir=0;
  261.  mm=1;             /* RIP MOD */
  262.  break;
  263.       case '<':
  264.       case '-':
  265.  if (curdir>0)
  266.    --curdir;
  267.  else {
  268.    while ((udir[curdir+1].subnum>=0) && (curdir<num_dirs-1))
  269.      ++curdir;
  270.  }
  271.  mm=1;             /* RIP MOD */
  272.  break;
  273.  
  274. Replace the case '?' further on down in DLMAINMENU()
  275.       
  276.       case '?':                                    /* RIP MOD */
  277.   if ((sysstatus_expert & thisuser.sysstatus)==0)  /* RIP MOD */
  278.      nl();                                         /* RIP MOD */
  279.      else                                          /* RIP MOD */
  280.       printmenu(0);                                /* Rip Mod */
  281.   break;                                           /* RIP MOD */
  282. =============================================================================
  283. [#6] [LOAD] MSGBASE.C   search and add the /* modded code */
  284. =============================================================================
  285. search for:
  286.  
  287. int printfile(char *fn)
  288.       ...etc...further on down.....
  289.       strcpy(s,syscfg.gfilesdir);
  290.     m.stored_as=0L;
  291.     m.storage_type=255;
  292.     strcat(s,fn);
  293.     if (strstr(s,".RIP"))              /* if a file is    */
  294.        ripflg=1;                       /* to be loaded,   */
  295.     if (strchr(s,'.')==NULL) {         /* and has an ext  */
  296.     if (rip) {                         /* of .RIP then    */
  297.        strcpy(s1,s);                   /* it disables     */
  298.        strcat(s1,".RIP");              /* [PAUSE] temporar*/
  299.        if (exist(s1)) {                /* ily.            */
  300.           strcat(s,".RIP");            /*                 */
  301.           ripflg=1;                    /*   R.I.P MOD     */
  302.           }                            /*      BY         */
  303.      }                                 /*    MIDIMAN      */
  304.    }                                   /*                 */
  305.    if (strchr(s,'.')==NULL) {      
  306.    if (thisuser.sysstatus & sysstatus_ansi) {
  307.  if (thisuser.sysstatus & sysstatus_color) {
  308.    strcpy(s1,s);
  309.  
  310.   go down further at the end in printfile() and look for 
  311.  
  312.   next=0;
  313.   read_message1(&m,0,0,&next,s);
  314.   ripflg=0;                            /* RIP MOD, turns on pause again */
  315.   return(next);
  316. }
  317.  
  318. save msgbase.c
  319. =============================================================================
  320. [#7] [LOAD] COM.C   search and add the /* modded code */
  321. =============================================================================
  322. look for:
  323. void pausescr(void)
  324. {
  325.   int i,i1;
  326.   char *ss;
  327.  
  328.   if (ripflg) {                /* RIP MOD */
  329.     lines_listed=0;            /* RIP MOD resets lines to 0 */
  330.     return;                    /* RIP MOD */
  331.     }                          /* RIP MOD */
  332.  
  333.   if (x_only)
  334.     return;
  335.  
  336. * REPLACE this void *
  337. int yn(void)
  338. {
  339.   char ch=0;
  340.  
  341.   ansic(1);
  342.   while ((!hangup) &&
  343.          ((ch = upcase(getkey())) != *str_yes) &&
  344.          (ch != *str_no) &&
  345.          (ch != 13))
  346.   if (!rip) {
  347.   if (ch==*str_yes)
  348.     print_yn(2);
  349.   else
  350.     print_yn(3);
  351.     }
  352.   return(ch == *str_yes);
  353. }
  354.  
  355. save com.c
  356. =============================================================================
  357. [#8] [LOAD] LILO.C   search and add the /* modded code */
  358. =============================================================================
  359. look for:
  360. void getuser() (at the beginning)
  361.   
  362.   okmacro=0;
  363.   actsl=syscfg.newusersl;
  364.   if ((!net_only) && (incom)) {
  365.     ripcheck();                        /* RIP MOD */
  366.     sprintf(s,"%sWELCOME.ANS",languagedir);
  367.     if (exist(s)) {
  368.       nl();
  369.  
  370. Further on down.....
  371.       ans=check_ansi();
  372. #endif
  373.       if (rip) {                       /* RIP MOD  */
  374.       ripflg=1;                        /* RIP MOD  */
  375.       printfile ("welcome.rip");       /* RIP MOD  */
  376.       rippause();                      /* SEE NOTE */
  377.       } else                           /* RIP MOD  */
  378.       if (ans>0)
  379.  printfile("welcome.ans");
  380.       else if (ans==0)
  381.  
  382. further down look for this:      
  383.  
  384.       printfile("welcome.msg");
  385.   }
  386.   if (curatr!=7)
  387.     reset_colors();
  388.   ripwindow();                        /* RIP MOD */
  389.   do {
  390.     nl();
  391.     if (net_only) {
  392.  
  393.  * NOTE * I put RIPPAUSE() in there because my Welcome RIP has a button that 
  394.  is hit to continue. Take this out if you don't need a pause there.  But the
  395.  screens go by so quick, that you will need this!
  396.  
  397. look for and add the following in lilo.c  logon(void) 
  398.   
  399.   if (incom && live_user) {
  400.     i=printfile("LOGON");
  401.       rippause();        /* RIP MOD, so you can put a nifty pause button */
  402.     if ((!i) && (!(thisuser.sysstatus & sysstatus_pause_on_page)))
  403.       pausescr();
  404.   }
  405.   ripwindow();           /* RIP MOD, makes tty window */
  406.   strcpy(xdate,date());
  407.   if (strcmp(xdate,thisuser.laston)==0)
  408.     
  409. Further down in VOID LOGON() is :    
  410.  
  411.     prt(3,get_string(378));
  412.     nl();
  413.     nl();
  414.   }
  415.   save_status();
  416.   create_chain_file("CHAIN.TXT");
  417.   
  418. if (rip) {                                         /* RIP MOD */
  419.     sysoplog("User is using RIP! by MIDIMAN");     /* RIP MOD */
  420.     if ((sysstatus_expert & thisuser.sysstatus)==0)/* RIP MOD */
  421.        nl();                                       /* RIP MOD */
  422.     else                                           /* RIP MOD */
  423.        thisuser.sysstatus ^= sysstatus_expert;     /* RIP MOD */
  424.     }                                              /* RIP MOD */
  425. }    /* existing, its the last } in void LOGON */                                               
  426.  
  427.  SAVE LILO.C
  428.  
  429. ( NEED NEXT FILE - RIPMOD2a )
  430.  
  431.  
  432.  
  433.